package com.huayi.website.service.impl;

import com.huayi.website.entity.MessageBoardEntity;
import com.huayi.website.entity.NewsEntity;
import com.huayi.website.repository.MessageBoardRepository;
import com.huayi.website.service.MessageBoardService;
import com.huayi.website.utils.PagingResponse;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class MessageBoardServiceImpl implements MessageBoardService {
    @Autowired
    private MessageBoardRepository repository;

    @Override
    public PagingResponse<MessageBoardEntity> getList(int pageIndex, int pageSize, String linkMan, String phone, String email) {
        return repository.getList(pageIndex,pageSize,linkMan,phone,email);
    }

    @Override
    public Integer addMessage(String linkName, String linkPhone, String email, String content) {
        return repository.addMessage(linkName,linkPhone,email,content);
    }

    @Override
    public void messageReply(Integer messageId,String userName, String remark) {
        repository.messageReply(messageId,userName,remark);
    }
}
